move crusor automatically editor to terminal